const mongoose = require("mongoose");
Schema = mongoose.Schema;
const categorySchema = new Schema({
  name: {
    type: String
  },
  parent: {
    type: mongoose.SchemaTypes.ObjectId,
    ref: "Category"
  }
});

module.exports = mongoose.model("Category", categorySchema, "Categories");
